home *** CD-ROM | disk | FTP | other *** search
/ InfoMagic Internet Tools 1993 July / Internet Tools.iso / RockRidge / mail / mm / mm-0.90 / message.h < prev    next >
Encoding:
C/C++ Source or Header  |  1990-12-18  |  2.1 KB  |  82 lines

  1. /*
  2.  * Copyright (c) 1986, 1990 by The Trustees of Columbia University in
  3.  * the City of New York.  Permission is granted to any individual or
  4.  * institution to use, copy, or redistribute this software so long as it
  5.  * is not sold for profit, provided this copyright notice is retained.
  6.  */
  7.  
  8. #ifdef RCSID
  9. #ifndef lint
  10. static char *msg_rcsid = "$Header: /f/src2/encore.bin/cucca/mm/tarring-it-up/RCS/message.h,v 2.2 90/10/04 18:24:45 melissa Exp $";
  11. #endif
  12. #endif /* RCSID */
  13.  
  14. /*
  15.  * Header types
  16.  */
  17.  
  18. #define TO        1
  19. #define CC        2
  20. #define BCC        3
  21. #define FROM        4
  22. #define DATE        5
  23. #define SUBJECT        6
  24. #define REPLY_TO    7
  25. #define IN_REPLY_TO    8
  26. #define RESENT_TO    9
  27. #define RESENT_DATE    10
  28. #define RESENT_FROM    11
  29. #define SENDER        12
  30. #define REFERENCES    13
  31. #define COMMENTS    14
  32. #define MESSAGE_ID    15
  33. #define KEYWORDS    16
  34. #define ENCRYPTED    17
  35. #define RECEIVED    18
  36. #define USER_HEADERS    19
  37. #define FCC        20
  38. /*
  39.  * header flags
  40.  */
  41. #define HEAD_KNOWN 0x0001
  42. #define HEAD_UNKNOWN 0x0002
  43.  
  44. typedef struct headers {        /* define a message header */
  45.     int type;                /* type of header */
  46.     int flags;                /* info about the header. */
  47.     char *name;                /* name of the header */
  48.     struct headers *next;        /* next header */
  49. /* ******* the following should be made a union at some point, but the names
  50.    ******* are too general to make into #defines right now.
  51. */
  52.     addresslist *address;        /* address if an address field */
  53.     keylist keys;            /* place to hold a bunch of strings */
  54.     char *string;            /* or just a string otherwise */
  55. } headers;
  56.  
  57. typedef struct mail_msg {
  58.     headers *headers;            /* list of unordered headers */
  59.     headers *last;
  60.     char *body;                /* text of the message */
  61.     headers *to;            /* list of known headers for */
  62.     headers *cc;            /* reference and easy lookup */
  63.     headers *bcc;
  64.     headers *fcc;
  65.     headers *from;
  66.     headers *date;
  67.     headers *subject;
  68.     headers *reply_to;
  69.     headers *in_reply_to;
  70.     headers *resent_to;
  71.     headers *resent_date;
  72.     headers *resent_from;
  73.     headers *sender;
  74.     headers *references;
  75.     headers *comments;
  76.     headers *message_id;
  77.     headers *keywords;
  78.     headers *encrypted;
  79.     headers *received;
  80. } mail_msg;
  81.  
  82.